using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._ServerTools._Caching
{
    /// <summary>
    /// <para>Delete Map Server Cache</para>
    /// <para>Deletes an existing map image layer cache, including all associated files on disk.</para>
    /// <para>删除现有地图图像图层缓存，包括磁盘上的所有关联文件。</para>
    /// </summary>    
    [DisplayName("Delete Map Server Cache")]
    public class DeleteMapServerCache : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public DeleteMapServerCache()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_input_service">
        /// <para>Input Service</para>
        /// <para><xdoc>
        ///   <para>The map image layer whose cache tiles you want to delete. You can choose it by browsing to the desired service in Portal or you can drag and drop a web tile layer from the Project pane Portal tab to supply this parameter.</para>
        ///   <para>The map image layer whose cache tiles you want to delete.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>要删除其缓存切片的地图图像图层。您可以通过在门户中浏览到所需的服务来选择它，也可以从工程窗格门户选项卡拖放 Web 切片图层以提供此参数。</para>
        ///   <para>要删除其缓存切片的地图图像图层。</para>
        /// </xdoc></para>
        /// </param>
        public DeleteMapServerCache(object _input_service)
        {
            this._input_service = _input_service;
        }
        public override string ToolboxName => "Server Tools";

        public override string ToolName => "Delete Map Server Cache";

        public override string CallName => "server.DeleteMapServerCache";

        public override List<string> AcceptEnvironments => [];

        public override object[] ParameterInfo => [_input_service, _num_of_caching_service_instances, _out_job_url];

        /// <summary>
        /// <para>Input Service</para>
        /// <para><xdoc>
        ///   <para>The map image layer whose cache tiles you want to delete. You can choose it by browsing to the desired service in Portal or you can drag and drop a web tile layer from the Project pane Portal tab to supply this parameter.</para>
        ///   <para>The map image layer whose cache tiles you want to delete.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>要删除其缓存切片的地图图像图层。您可以通过在门户中浏览到所需的服务来选择它，也可以从工程窗格门户选项卡拖放 Web 切片图层以提供此参数。</para>
        ///   <para>要删除其缓存切片的地图图像图层。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Service")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _input_service { get; set; }


        /// <summary>
        /// <para>Number of caching service instances</para>
        /// <para>Defines the number of instances that will be used to update/generate the tiles. The value for this parameter is set to unlimited (-1) and cannot be modified.</para>
        /// <para>定义将用于更新/生成切片的实例数。此参数的值设置为无限制 （-1），无法修改。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Number of caching service instances")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public long? _num_of_caching_service_instances { get; set; } = null;


        /// <summary>
        /// <para>Output Map Service URL</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Map Service URL")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_job_url { get; set; }


        public DeleteMapServerCache SetEnv()
        {
            base.SetEnv();
            return this;
        }

    }

}